Conversation
Codecov Report❌ Patch coverage is
❌ Your patch status has failed because the patch coverage (0.00%) is below the target coverage (100.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## develop #1544 +/- ##
===========================================
- Coverage 40.75% 40.61% -0.14%
===========================================
Files 50 50
Lines 3914 3927 +13
Branches 1127 1130 +3
===========================================
Hits 1595 1595
- Misses 2196 2209 +13
Partials 123 123
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
lib/runner/index.js
Outdated
| * to indicate whether vault access check has been performed. | ||
| * @param {Number} [options.nestedRequest.invocationCount] - The number of requests currently accummulated | ||
| * by the nested request chain. | ||
| * @param {Array} [options.nestedRequest.nestingChain] - The current chain of nested request item ids |
lib/runner/nested-request.js
Outdated
| maxInvokableNestedRequests = _.get(self, 'options.maxInvokableNestedRequests'), | ||
| itemId = item.id, | ||
|
|
||
| nestingChainMetaForCurrentItem = { popped: false }, |
There was a problem hiding this comment.
isRemovedFromCallStack
Also, does this need to be an object? Can a simple Boolean work?
There was a problem hiding this comment.
This was done just for the runtime's excessive checks on const and lets being in the same block 😅 Have renamed and moved it but will need an eslint-disable comment at the end.
| itemIndex = callStack.lastIndexOf(itemId); | ||
|
|
||
| if (itemIndex !== -1) { | ||
| self.state.nestedRequest.callStack.splice(itemIndex, 1); |
There was a problem hiding this comment.
you can directly use the destructured variable callStack
There was a problem hiding this comment.
So I have preferred not updating the destructured variable as I am trying to ensure the mutations go to the self.state.nestedRequest object, which is shared across runs.
There was an issue in the app that gets fixed only if all mutations to nested properties go via this chain instead of a destructured variable.
lib/runner/nested-request.js
Outdated
| }); | ||
|
|
||
| self.state.nestedRequest.invocationCount++; | ||
| self.state.nestedRequest.callStack = self.state.nestedRequest.callStack || []; |
There was a problem hiding this comment.
Is this needed even when we are setting the default [] above?
No description provided.